package jw.hospital.hosp.model.config;

import com.baomidou.mybatisplus.core.config.GlobalConfig;
import jw.hospital.hosp.model.handler.MetaHandler;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class MybatisPlusConfig {

    //自动填充功能
    @Bean
    public  GlobalConfig globalConfig(){
        GlobalConfig  globalConfig =new GlobalConfig();
        globalConfig.setMetaObjectHandler(new MetaHandler());
        return globalConfig;
    }
}
